<? if(isset($grocery)){?>
<table cellpadding="5px">
<tbody id="table">
	<tr>
		<th scope="col">Item Name</th>
		<th scope="col">Item Brand</th>
		<th scope="col">Quantity</th>
		<th scope="col">Date</th>
		<th scope="col">Schedule</th>
		<th scope="col">Manage</th>

	</tr>


  <?php foreach($grocery as $item):?>
   
  <tr class="center" id="<?=$item->id ?>">
  <td style="display:none">
  <input type="hidden" id="gid<?=$item->id?>" value="<?=$item->id?>" /></td>
		<td id="name<?=$item->id?>"><?=$item->name;?></td>
		<td id="brand<?=$item->id?>"><?=$item->brand;?></td>
		<td id="quantity<?=$item->id?>"><?=$item->quantity;?></td>
		<td id="date<?=$item->id?>"><?=$item->date;?></td>
		<td id="schedule<?=$item->id?>"><?=$item->schedule;?></td>
		<td>
        <?php
       
           echo '<img src="'.base_url().$this->config->item('FAL_assets_admin').'/'.$this->config->item('FAL_images').'/pencil.png" alt="edit" title="edit" onclick="javascript:edit(\''.$item->id.'\')" >';
       
            echo '<img src="'.base_url().$this->config->item('FAL_assets_admin').'/'.$this->config->item('FAL_images').'/cross.png" alt="delete" title="delete" onclick="javascript:delete_grocery(\''.$item->id.'\')" >';
        ?>
    </td>

	</tr>
  <?php endforeach;?>

</tbody>
</table>
<?} else{
  echo "You Don't Have any Grocery Items Added Till Now...";
  }?>